package com.updesignsz.admin.service;

import com.updesignsz.admin.mapper.TypeMapper;
import com.updesignsz.admin.vo.form.TypeForm;
import com.updesignsz.commom.entity.Type;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 项目类型
 * Creation date 2020-8-8 17:53:48
 */
@Service
public class TypeService {

	@Autowired
	private TypeMapper typeMapper;


	public void deleteType(Integer id) {
		typeMapper.deleteType(id);
	}

	public List<Type> listAll(Type type) {
		return typeMapper.listAll(type);
	}

	public void saveType(TypeForm form) {
		typeMapper.saveType(form);
	}

	public void updateType(TypeForm form) {
		typeMapper.updateType(form);
	}

	public Type getById(Integer id) {
		return typeMapper.getById(id);
	}
}